package com.ltv.xiangqibook.common;

import java.io.File;

public class GameIDCreator {
    public static String getGameURL(File pgnFile) throws Exception {
        return pgnFile.getAbsolutePath().replace(XiangQiBookConfiguration.getInstance().getBookLocalLocation(), "");
    }
    
    public static String getGameID(File pgnFile) throws Exception {
        return MD5Util.md5(getGameURL(pgnFile));
    }
}
